<%@ page language="java" import="up7.*" pageEncoding="UTF-8"%>
<%@ page contentType="text/html;charset=UTF-8"%>
<%@	page import="com.google.gson.Gson" %>
<%@ page import="up7.model.*" %>
<%@ page import="up7.biz.*" %>
<%@ page import="up7.utils.*" %>
<%@	page import="org.apache.commons.lang.StringUtils" %>
<%@ page import="java.net.URLDecoder" %>
<%@ page import="java.net.URLEncoder" %>
<%@ page import="net.sf.json.JSONObject" %>
<%@ page import="up7.sql.SqlWhereMerge" %>
<%@ page import="up7.sql.SqlExec" %>
<%@ page import="net.sf.json.JSONArray" %>
<%@ page import="filemgr.PageFileMgr" %>
<%@ page import="java.io.UnsupportedEncodingException" %>
<%
    out.clear();

    WebBase web = new WebBase(pageContext);


    String id		= web.queryString("id");
    String pag		= web.queryString("page");
    String callback = web.queryString("callback");

    if (StringUtils.isBlank(id))
    {
        web.toContent(callback + "({\"value\":null})");
        return;
    }
    FolderBuilder fb = new FolderBuilder();
    Gson gson = new Gson();
    String json = gson.toJson(fb.build(id));
    json = PathTool.url_encode(json);
    json = callback + "({\"value\":\"" + json + "\"})";//返回jsonp格式数据。
    out.write(json);
%>